]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
status/network: Notify icon change after access-point update
authorFlorian Müllner <fmuellner@gnome.org>
Thu, 4 Aug 2022 22:39:47 +0000 (00:39 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Sun, 7 Aug 2022 20:41:09 +0000 (22:41 +0200)
We call sync() which updates our own label and icon, but does
not notify the indicator about the icon change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2406>

js/ui/status/network.js

index 904abf5849201a5144cd55c0c90217d3e45960ee..d6cad562411938beee53c26833d6361302df16d5 100644 (file)
@@ -1329,19 +1329,14 @@ var NMDeviceWireless = class extends Signals.EventEmitter {
         this._dialog = null;
     }
 
-    _strengthChanged() {
-        this._iconChanged();
-    }
-
     _activeApChanged() {
         this._activeAccessPoint?.disconnectObject(this);
-
         this._activeAccessPoint = this._device.active_access_point;
+        this._activeAccessPoint?.connectObject(
+            'notify::strength', () => this._iconChanged(),
+            this);
 
-        this._activeAccessPoint?.connectObject('notify::strength',
-            this._strengthChanged.bind(this), this);
-
-        this._sync();
+        this._iconChanged();
     }
 
     _sync() {